<script lang="ts">
import {defineComponent} from 'vue'

export default defineComponent({
  name: "BtnPopover",
  props: {
    icon:{
      type:String,
      default: ()=>''
    },
    word:{
      type:String,
      default: ()=>''
    },
    width: {
      type:String,
      default:()=>'150px'
    }
  },
})
</script>

<template>
  <el-popover placement="top"
              popper-style="box-sizing: border-box;"
              trigger="click"
              :width="width">
    <slot></slot>
    <template #reference>
      <el-button
        text
        @click.stop
        :icon="icon"
        type="primary">
        {{word}}
      </el-button>
    </template>
  </el-popover>
</template>

<style scoped lang="scss">

</style>
